'use strict';
/**
 * @author {JC}
 * @date 2022-10-01
 * **/
const Controller = require('egg').Controller;
class Socket extends Controller {
    /**
     * @effect 即时通讯
     * **/
    async takeChatOneByOne(){
        const {ctx, app} = this;
        const message =ctx.arg[0];
        await ctx.socket.emit('room', `Hi!${ctx.socket.id}我是服务端，收到了你的信息：${message}`)      
    }
}
module.exports = Socket;